package org.wlc.demov1;

import java.util.Date;
import java.util.Map;
import java.util.concurrent.ConcurrentHashMap;

/**
 * @author 王立朝
 * @date 2022/5/17
 * @description: 模拟审核和查询审核结果的服务类
 */
public class AuthService {

    private static Map<String, Date> map = new ConcurrentHashMap<>();

    /**
     * 查询审核结果
     */

    public static Date queryAuthInfo(String uid, String orderId) {

        return map.get(uid.concat(orderId));
    }

    /**
     * 模拟审核
     *
     * @param uid
     * @param orderId
     */
    public static void auth(String uid, String orderId) {
        map.put(uid.concat(orderId), new Date());
    }
}
